package utils

/*
import (
	"database/sql"
	"fmt"
	_ "github.com/go-sql-driver/mysql"
	"log"
)

var db *sql.DB


func init() {
	uri := "root:12345678@tcp(172.16.8.181:3307)/test?charset=utf8"
	if db1, err := sql.Open("mysql", uri); err != nil {
		fmt.Println("连接失败" + err.Error())
	} else {
		db = db1
	}

}
func Select(sql string,ret interface{})  {

}
func ExecSql(sql string, args ...interface{}) (int64, error) {
	if re, err := db.Exec(sql, args...); err != nil {
		return 0, err
	} else {
		count, err := re.RowsAffected()
		if err != nil {
			log.Println(err)
			return 0, err
		}
		return count, nil
	}

}
*/
